package mk.com.ldm.corepoint.implementation.client.lib.generators;

import com.google.gwt.event.shared.GwtEvent;

public class AddEvent extends GwtEvent<AddEventHandler>{
	public static Type<AddEventHandler> TYPE = new Type<AddEventHandler>();
	private String id;
	private String name;
	
	public AddEvent(){}
	
	public AddEvent(String id, String name){
		this.id = id;
		this.name = name;
	}

	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	@Override
	public Type<AddEventHandler> getAssociatedType() {
		return TYPE;
	}

	@Override
	protected void dispatch(AddEventHandler handler) {
		handler.onAdd(this);
	}

}
